package com.pdf.pdfserver.listener;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.context.event.EventListener;
import org.springframework.stereotype.Component;
import org.springframework.web.context.support.ServletRequestHandledEvent;

/**
 * @Author songfz
 * @Description 监听DispatcherServlet请求
 * @Date 2022/2/7
 */
@Component
public class HttpListener {

    private static  Logger LOG = LoggerFactory.getLogger(HttpListener.class);


    @EventListener
    public void ex(ServletRequestHandledEvent event){

        LOG.info("http请求记录：【{}】",event.getRequestUrl());
    }
}
